package com.rainy.cloud.gateway.route.properties;

import com.rainy.cloud.gateway.route.entity.Route;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 *  如果是相同的key，则最后一个起作用
 */
@Data
@Component
@PropertySource({"classpath:route.properties"})
@ConfigurationProperties(prefix = "app.consumer")
public class RouteProperties {
    List<Route> routes;
}
